[<<Previous Entry]
[^^Up^^]
[Next Entry>>]
[Menu]
[About The Guide]
OR(IEXP1,IEXP2) (INTEGER)
Function
Calculate the bitwise OR of two integer arguments.
Syntax
OR(iexp1,iexp2)
iexp1 = Any integer expression.
iexp2 = Any integer expression.
Return Type & Value
INTEGER
Returns the bitwise OR of iexp1 and iexp2.
Remarks
This function may be used to set selected bits in an integer expression
by ORing the expression with a mask that has the bits to set set to 1 and
the bits to ignore set to 0.
Examples
' Set the bits in the low byte
PRINTLN OR(1248h,00FFh)
' Randomly set a flag the hard way
INTEGER flag
LET flag = OR(RANDOM(1),RANDOM(1))
See Also:
AND()
NOT()
XOR()
This page created by ng2html v1.05, the Norton guide to HTML conversion utility.
Written by Dave Pearson